package com.nowcoder.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.nowcoder.entity.Comment;

import java.util.List;

public interface CommentService extends IService<Comment> {

    /**
     *
     * @param entityType
     * @param entityId
     * @param offset
     * @param limit
     * @return
     */
    public List<Comment> selectCommentByEntity(int entityType, int entityId, int offset, int limit);

    /**
     *
     * @param entityType
     * @param entityId
     * @return
     */
    public int selectCountByEntity(int entityType, int entityId);

    /**
     *
     * @param comment
     * @return
     */
    public int insertComment(Comment comment);
}
